package edu.sctu.zhuyingzhi.month201505.day20150514.mapTest;

import java.util.*;

/**
 * Created by user13 on 2015/5/14.
 */
public class AddList {
    //    public Map add(){
    public static void main(String[] args) {
        int i;

        Map map = new HashMap<>();

        map.put("name", "zyz");
        map.put("age", 123);

        map.put("test",new Worker(18,"朱英志","男",12000));
        map.put(1,new Worker(20,"夏磊","男",3800));
        map.put(3,new Worker(22,"黄天林","男",2800));

//        map.remove(2);
        i = (int) map.get("age");
        Worker worker = (Worker) map.get("test");

        System.out.println(worker.getName());
    }
//
//        return map;
//    }
}
